#-*- coding: utf -8 -*-

import sys

def fatorial(n):
    if n<= 0:
        return 1
    else:
        return n * fatorial(n-1)


def fatorial_cauda(n):
    def fact(i=n, acc=1):
        if i== 0:
            return acc
        else:
            return fact(i-1, (acc * i))
        return fact()


fatorial_cauda(5)
